{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Applying different distributions to collections and images"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [],
   "source": [
    "import ee\n",
    "ee.Initialize()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [],
   "source": [
    "from geetools import tools"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [],
   "source": [
    "import ipygee as ui"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [],
   "source": [
    "p = ee.Geometry.Point([0, 0])"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Build a Test Collection"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [],
   "source": [
    "# values = ee.List([0, 2, 5, 8, 10, 12, 15, 18, 22, 25, 28, 31, 35, 39, 42, 48, 51, 55])\n",
    "# values = ee.List([-10, -8, -7, -1, -2, 0, 1, 5, 7, 8, 10, 12, 14, 16, 18, 20, 22, 24])  # With negative values\n",
    "values = ee.List([-20, -32, -15, -8, -5, 0, 2, 4, 6, 8, 9, 10, 12, 14, 16, 18, 20, 23])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [],
   "source": [
    "def build_collection(n):\n",
    "    n = ee.Number(n)\n",
    "    return ee.Image.constant(n).rename('test').set('test', n).toFloat()\n",
    "images = values.map(build_collection)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [],
   "source": [
    "collection = ee.ImageCollection.fromImages(images)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Linear Function"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Using a band"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Help on function linearFunctionBand in module geetools.tools.imagecollection:\n",
      "\n",
      "linearFunctionBand(collection, band, range_min=None, range_max=None, mean=None, output_min=None, output_max=None, name='linear_function')\n",
      "    Apply a linear function over the bands across every image of the\n",
      "    ImageCollection using the following formula:\n",
      "    \n",
      "    - a = abs(val-mean)\n",
      "    - b = output_max-output_min\n",
      "    - c = abs(range_max-mean)\n",
      "    - d = abs(range_min-mean)\n",
      "    - e = max(c, d)\n",
      "    \n",
      "    f(x) = a*(-1)*(b/e)+output_max\n",
      "    \n",
      "    :param band: the band to process\n",
      "    :param range_min: the minimum pixel value in the parsed band. If None, it\n",
      "        will be computed reducing the collection\n",
      "    :param range_max: the maximum pixel value in the parsed band. If None, it\n",
      "        will be computed reducing the collection\n",
      "    :param output_min: the minimum value that will take the resulting band.\n",
      "    :param output_max: the minimum value that will take the resulting band.\n",
      "    :param mean: the value on the given range that will take the `output_max`\n",
      "        value\n",
      "    :param name: the name of the resulting band\n",
      "    :return: the parsed collection in which every image will have an extra band\n",
      "        that results of applying the linear function over every pixel in the\n",
      "        image\n",
      "    :rtype: ee.ImageCollection\n",
      "\n"
     ]
    }
   ],
   "source": [
    "help(tools.imagecollection.linearFunctionBand)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band1 = tools.imagecollection.linearFunctionBand(collection, 'test')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band1_chart = ui.chart.Image.series(linear_band1, p, scale=1000, xProperty='test', bands=['linear_function'], label_bands=['default values'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band2 = tools.imagecollection.linearFunctionBand(collection, 'test', mean=10)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band2_chart = ui.chart.Image.series(linear_band2, p, scale=1000, xProperty='test', bands=['linear_function'], label_bands=['mean=10'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band3 = tools.imagecollection.linearFunctionBand(collection, 'test', mean=10, output_min=0)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band3_chart = ui.chart.Image.series(linear_band3, p, scale=1000, xProperty='test', bands=['linear_function'], label_bands=['mean=10 min=0'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band4 = tools.imagecollection.linearFunctionBand(collection, 'test', mean=10, output_min=10, output_max=20)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_band4_chart = ui.chart.Image.series(linear_band4, p, scale=1000, xProperty='test', bands=['linear_function'], label_bands=['mean=10 min=0 max=12'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.jupyter.widget-view+json": {
       "model_id": "a9c7064e5d014bceb4341e6ea6b118a9",
       "version_major": 2,
       "version_minor": 0
      },
      "text/plain": [
       "HTML(value='<embed src=data:image/svg+xml;charset=utf-8;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTg…"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "linear_chart = linear_band1_chart.cat(linear_band2_chart, linear_band3_chart, linear_band4_chart)\n",
    "linear_chart.renderWidget(width=800)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Using a Property"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop1 = tools.imagecollection.linearFunctionProperty(collection, 'test')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop1_chart = ui.chart.Image.series(linear_prop1, p, scale=1000, xProperty='test', properties=['LINEAR_FUNCTION'], label_properties=['default values'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 20,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop2 = tools.imagecollection.linearFunctionProperty(collection, 'test', mean=10)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop2_chart = ui.chart.Image.series(linear_prop2, p, scale=1000, xProperty='test', properties=['LINEAR_FUNCTION'], label_properties=['mean=10'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 22,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop3 = tools.imagecollection.linearFunctionProperty(collection, 'test', mean=10, output_min=0)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop3_chart = ui.chart.Image.series(linear_prop3, p, scale=1000, xProperty='test', properties=['LINEAR_FUNCTION'], label_properties=['mean=10 min=0'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 24,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop4 = tools.imagecollection.linearFunctionProperty(collection, 'test', mean=10, output_min=0, output_max=10)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 25,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop4_chart = ui.chart.Image.series(linear_prop4, p, scale=1000, xProperty='test', properties=['LINEAR_FUNCTION'], label_properties=['mean=10 min=0 max=10'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 26,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop5 = tools.imagecollection.linearFunctionProperty(collection, 'test', mean=10, output_min=5, output_max=20)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 27,
   "metadata": {},
   "outputs": [],
   "source": [
    "linear_prop5_chart = ui.chart.Image.series(linear_prop5, p, scale=1000, xProperty='test', properties=['LINEAR_FUNCTION'], label_properties=['mean=10 min=5 max=20'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 28,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.jupyter.widget-view+json": {
       "model_id": "d00b369303644a16a5f955c304e015d6",
       "version_major": 2,
       "version_minor": 0
      },
      "text/plain": [
       "HTML(value='<embed src=data:image/svg+xml;charset=utf-8;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTg…"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "linear_chart_prop = linear_prop1_chart.cat(linear_prop2_chart, linear_prop3_chart, linear_prop4_chart, linear_prop5_chart)\n",
    "linear_chart_prop.renderWidget(width=800)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>mean=10 min=0</th>\n",
       "      <th>mean=10 min=0 max=10</th>\n",
       "      <th>mean=10 min=5 max=20</th>\n",
       "      <th>mean=10</th>\n",
       "      <th>default values</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>-32</th>\n",
       "      <td>-3.552714e-15</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>5.000000</td>\n",
       "      <td>-32.000000</td>\n",
       "      <td>-32.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-20</th>\n",
       "      <td>6.571429e+00</td>\n",
       "      <td>2.857143</td>\n",
       "      <td>9.285714</td>\n",
       "      <td>-16.285714</td>\n",
       "      <td>-20.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-15</th>\n",
       "      <td>9.309524e+00</td>\n",
       "      <td>4.047619</td>\n",
       "      <td>11.071429</td>\n",
       "      <td>-9.738095</td>\n",
       "      <td>-15.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-8</th>\n",
       "      <td>1.314286e+01</td>\n",
       "      <td>5.714286</td>\n",
       "      <td>13.571429</td>\n",
       "      <td>-0.571429</td>\n",
       "      <td>-8.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-5</th>\n",
       "      <td>1.478571e+01</td>\n",
       "      <td>6.428571</td>\n",
       "      <td>14.642857</td>\n",
       "      <td>3.357143</td>\n",
       "      <td>-5.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1.752381e+01</td>\n",
       "      <td>7.619048</td>\n",
       "      <td>16.428571</td>\n",
       "      <td>9.904762</td>\n",
       "      <td>0.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1.861905e+01</td>\n",
       "      <td>8.095238</td>\n",
       "      <td>17.142857</td>\n",
       "      <td>12.523810</td>\n",
       "      <td>2.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>1.971429e+01</td>\n",
       "      <td>8.571429</td>\n",
       "      <td>17.857143</td>\n",
       "      <td>15.142857</td>\n",
       "      <td>4.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>2.080952e+01</td>\n",
       "      <td>9.047619</td>\n",
       "      <td>18.571429</td>\n",
       "      <td>17.761905</td>\n",
       "      <td>6.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>2.190476e+01</td>\n",
       "      <td>9.523810</td>\n",
       "      <td>19.285714</td>\n",
       "      <td>20.380952</td>\n",
       "      <td>8.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>2.245238e+01</td>\n",
       "      <td>9.761905</td>\n",
       "      <td>19.642857</td>\n",
       "      <td>21.690476</td>\n",
       "      <td>9.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>2.300000e+01</td>\n",
       "      <td>10.000000</td>\n",
       "      <td>20.000000</td>\n",
       "      <td>23.000000</td>\n",
       "      <td>10.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>2.190476e+01</td>\n",
       "      <td>9.523810</td>\n",
       "      <td>19.285714</td>\n",
       "      <td>20.380952</td>\n",
       "      <td>12.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>2.080952e+01</td>\n",
       "      <td>9.047619</td>\n",
       "      <td>18.571429</td>\n",
       "      <td>17.761905</td>\n",
       "      <td>14.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>1.971429e+01</td>\n",
       "      <td>8.571429</td>\n",
       "      <td>17.857143</td>\n",
       "      <td>15.142857</td>\n",
       "      <td>16.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>1.861905e+01</td>\n",
       "      <td>8.095238</td>\n",
       "      <td>17.142857</td>\n",
       "      <td>12.523810</td>\n",
       "      <td>18.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>1.752381e+01</td>\n",
       "      <td>7.619048</td>\n",
       "      <td>16.428571</td>\n",
       "      <td>9.904762</td>\n",
       "      <td>20.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>1.588095e+01</td>\n",
       "      <td>6.904762</td>\n",
       "      <td>15.357143</td>\n",
       "      <td>5.976190</td>\n",
       "      <td>23.0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     mean=10 min=0  mean=10 min=0 max=10  mean=10 min=5 max=20    mean=10  \\\n",
       "-32  -3.552714e-15              0.000000              5.000000 -32.000000   \n",
       "-20   6.571429e+00              2.857143              9.285714 -16.285714   \n",
       "-15   9.309524e+00              4.047619             11.071429  -9.738095   \n",
       "-8    1.314286e+01              5.714286             13.571429  -0.571429   \n",
       "-5    1.478571e+01              6.428571             14.642857   3.357143   \n",
       " 0    1.752381e+01              7.619048             16.428571   9.904762   \n",
       " 2    1.861905e+01              8.095238             17.142857  12.523810   \n",
       " 4    1.971429e+01              8.571429             17.857143  15.142857   \n",
       " 6    2.080952e+01              9.047619             18.571429  17.761905   \n",
       " 8    2.190476e+01              9.523810             19.285714  20.380952   \n",
       " 9    2.245238e+01              9.761905             19.642857  21.690476   \n",
       " 10   2.300000e+01             10.000000             20.000000  23.000000   \n",
       " 12   2.190476e+01              9.523810             19.285714  20.380952   \n",
       " 14   2.080952e+01              9.047619             18.571429  17.761905   \n",
       " 16   1.971429e+01              8.571429             17.857143  15.142857   \n",
       " 18   1.861905e+01              8.095238             17.142857  12.523810   \n",
       " 20   1.752381e+01              7.619048             16.428571   9.904762   \n",
       " 23   1.588095e+01              6.904762             15.357143   5.976190   \n",
       "\n",
       "     default values  \n",
       "-32           -32.0  \n",
       "-20           -20.0  \n",
       "-15           -15.0  \n",
       "-8             -8.0  \n",
       "-5             -5.0  \n",
       " 0              0.0  \n",
       " 2              2.0  \n",
       " 4              4.0  \n",
       " 6              6.0  \n",
       " 8              8.0  \n",
       " 9              9.0  \n",
       " 10            10.0  \n",
       " 12            12.0  \n",
       " 14            14.0  \n",
       " 16            16.0  \n",
       " 18            18.0  \n",
       " 20            20.0  \n",
       " 23            23.0  "
      ]
     },
     "execution_count": 29,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "linear_chart_prop.dataframe"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Gauss Function"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Over a band"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band1 = tools.imagecollection.gaussFunctionBand(collection, 'test')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 31,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band1_chart = ui.chart.Image.series(gauss_band1, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', bands=['gauss'], label_bands=['defualt'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band2 = tools.imagecollection.gaussFunctionBand(collection, 'test', mean=10)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 33,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band2_chart = ui.chart.Image.series(gauss_band2, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', bands=['gauss'], label_bands=['mean=10'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 34,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band3 = tools.imagecollection.gaussFunctionBand(collection, 'test', mean=10, output_min=0.5)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band3_chart = ui.chart.Image.series(gauss_band3, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', bands=['gauss'], label_bands=['mean=10 min=0.5'])"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Exponential function using the gauss function\n",
    "Use as mean value the range_max"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band4 = tools.imagecollection.gaussFunctionBand(collection, 'test', mean=23, output_min=0.5)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 37,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_band4_chart = ui.chart.Image.series(gauss_band4, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', bands=['gauss'], label_bands=['Exponential'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.jupyter.widget-view+json": {
       "model_id": "fea4ee6db33448c98af370e0ff663f44",
       "version_major": 2,
       "version_minor": 0
      },
      "text/plain": [
       "HTML(value='<embed src=data:image/svg+xml;charset=utf-8;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTg…"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "gauss_band_chart = gauss_band1_chart.cat(gauss_band2_chart, gauss_band3_chart, gauss_band4_chart)\n",
    "gauss_band_chart.renderWidget(width=800)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 39,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>defualt</th>\n",
       "      <th>mean=10 min=0.5</th>\n",
       "      <th>mean=10</th>\n",
       "      <th>Exponential</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>-32</th>\n",
       "      <td>0.066663</td>\n",
       "      <td>0.500000</td>\n",
       "      <td>0.009418</td>\n",
       "      <td>0.500000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-20</th>\n",
       "      <td>0.347201</td>\n",
       "      <td>0.541954</td>\n",
       "      <td>0.092535</td>\n",
       "      <td>0.503594</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-15</th>\n",
       "      <td>0.551540</td>\n",
       "      <td>0.591904</td>\n",
       "      <td>0.191495</td>\n",
       "      <td>0.510812</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-8</th>\n",
       "      <td>0.844293</td>\n",
       "      <td>0.709511</td>\n",
       "      <td>0.424493</td>\n",
       "      <td>0.539220</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-5</th>\n",
       "      <td>0.936023</td>\n",
       "      <td>0.773638</td>\n",
       "      <td>0.551540</td>\n",
       "      <td>0.562733</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1.000000</td>\n",
       "      <td>0.882704</td>\n",
       "      <td>0.767618</td>\n",
       "      <td>0.623294</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>0.989477</td>\n",
       "      <td>0.921406</td>\n",
       "      <td>0.844293</td>\n",
       "      <td>0.655646</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.958569</td>\n",
       "      <td>0.954161</td>\n",
       "      <td>0.909185</td>\n",
       "      <td>0.692359</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>0.909185</td>\n",
       "      <td>0.979087</td>\n",
       "      <td>0.958569</td>\n",
       "      <td>0.732741</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>0.844293</td>\n",
       "      <td>0.994689</td>\n",
       "      <td>0.989477</td>\n",
       "      <td>0.775695</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>0.807175</td>\n",
       "      <td>0.998667</td>\n",
       "      <td>0.997359</td>\n",
       "      <td>0.797684</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>0.767618</td>\n",
       "      <td>1.000000</td>\n",
       "      <td>1.000000</td>\n",
       "      <td>0.819730</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>0.683296</td>\n",
       "      <td>0.994689</td>\n",
       "      <td>0.989477</td>\n",
       "      <td>0.863029</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>0.595504</td>\n",
       "      <td>0.979087</td>\n",
       "      <td>0.958569</td>\n",
       "      <td>0.903555</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>0.508127</td>\n",
       "      <td>0.954161</td>\n",
       "      <td>0.909185</td>\n",
       "      <td>0.939209</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>0.424493</td>\n",
       "      <td>0.921406</td>\n",
       "      <td>0.844293</td>\n",
       "      <td>0.968001</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>0.347201</td>\n",
       "      <td>0.882704</td>\n",
       "      <td>0.767618</td>\n",
       "      <td>0.988236</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>0.246842</td>\n",
       "      <td>0.818077</td>\n",
       "      <td>0.639581</td>\n",
       "      <td>1.000000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      defualt  mean=10 min=0.5   mean=10  Exponential\n",
       "-32  0.066663         0.500000  0.009418     0.500000\n",
       "-20  0.347201         0.541954  0.092535     0.503594\n",
       "-15  0.551540         0.591904  0.191495     0.510812\n",
       "-8   0.844293         0.709511  0.424493     0.539220\n",
       "-5   0.936023         0.773638  0.551540     0.562733\n",
       " 0   1.000000         0.882704  0.767618     0.623294\n",
       " 2   0.989477         0.921406  0.844293     0.655646\n",
       " 4   0.958569         0.954161  0.909185     0.692359\n",
       " 6   0.909185         0.979087  0.958569     0.732741\n",
       " 8   0.844293         0.994689  0.989477     0.775695\n",
       " 9   0.807175         0.998667  0.997359     0.797684\n",
       " 10  0.767618         1.000000  1.000000     0.819730\n",
       " 12  0.683296         0.994689  0.989477     0.863029\n",
       " 14  0.595504         0.979087  0.958569     0.903555\n",
       " 16  0.508127         0.954161  0.909185     0.939209\n",
       " 18  0.424493         0.921406  0.844293     0.968001\n",
       " 20  0.347201         0.882704  0.767618     0.988236\n",
       " 23  0.246842         0.818077  0.639581     1.000000"
      ]
     },
     "execution_count": 39,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "gauss_band_chart.dataframe"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Over a Property"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 40,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_prop1 = tools.imagecollection.gaussFunctionProperty(collection, 'test')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 41,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_prop1_chart = ui.chart.Image.series(gauss_prop1, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', properties=['GAUSS'], label_properties=['defualt'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 42,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_prop2 = tools.imagecollection.gaussFunctionProperty(collection, 'test', mean=10)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 43,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_prop2_chart = ui.chart.Image.series(gauss_prop2, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', properties=['GAUSS'], label_properties=['mean=10'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 44,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_prop3 = tools.imagecollection.gaussFunctionProperty(collection, 'test', mean=10, output_min=0.5)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 45,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_prop3_chart = ui.chart.Image.series(gauss_prop3, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', properties=['GAUSS'], label_properties=['mean=10 min=0.5'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 46,
   "metadata": {},
   "outputs": [],
   "source": [
    "gauss_prop = gauss_prop1_chart.cat(gauss_prop2_chart, gauss_prop3_chart)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 47,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.jupyter.widget-view+json": {
       "model_id": "431873edc8654a9bb4e0807234f13984",
       "version_major": 2,
       "version_minor": 0
      },
      "text/plain": [
       "HTML(value='<embed src=data:image/svg+xml;charset=utf-8;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTg…"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "gauss_prop.renderWidget(width=800)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 48,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>defualt</th>\n",
       "      <th>mean=10 min=0.5</th>\n",
       "      <th>mean=10</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>-32</th>\n",
       "      <td>0.066663</td>\n",
       "      <td>0.500000</td>\n",
       "      <td>0.009418</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-20</th>\n",
       "      <td>0.347201</td>\n",
       "      <td>0.541954</td>\n",
       "      <td>0.092535</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-15</th>\n",
       "      <td>0.551540</td>\n",
       "      <td>0.591904</td>\n",
       "      <td>0.191495</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-8</th>\n",
       "      <td>0.844293</td>\n",
       "      <td>0.709511</td>\n",
       "      <td>0.424493</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-5</th>\n",
       "      <td>0.936023</td>\n",
       "      <td>0.773638</td>\n",
       "      <td>0.551540</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1.000000</td>\n",
       "      <td>0.882704</td>\n",
       "      <td>0.767618</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>0.989477</td>\n",
       "      <td>0.921406</td>\n",
       "      <td>0.844293</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.958569</td>\n",
       "      <td>0.954161</td>\n",
       "      <td>0.909185</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>0.909185</td>\n",
       "      <td>0.979087</td>\n",
       "      <td>0.958569</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>0.844293</td>\n",
       "      <td>0.994689</td>\n",
       "      <td>0.989477</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>0.807175</td>\n",
       "      <td>0.998667</td>\n",
       "      <td>0.997359</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>0.767618</td>\n",
       "      <td>1.000000</td>\n",
       "      <td>1.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>0.683296</td>\n",
       "      <td>0.994689</td>\n",
       "      <td>0.989477</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>0.595504</td>\n",
       "      <td>0.979087</td>\n",
       "      <td>0.958569</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>0.508127</td>\n",
       "      <td>0.954161</td>\n",
       "      <td>0.909185</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>0.424493</td>\n",
       "      <td>0.921406</td>\n",
       "      <td>0.844293</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>0.347201</td>\n",
       "      <td>0.882704</td>\n",
       "      <td>0.767618</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>0.246842</td>\n",
       "      <td>0.818077</td>\n",
       "      <td>0.639581</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      defualt  mean=10 min=0.5   mean=10\n",
       "-32  0.066663         0.500000  0.009418\n",
       "-20  0.347201         0.541954  0.092535\n",
       "-15  0.551540         0.591904  0.191495\n",
       "-8   0.844293         0.709511  0.424493\n",
       "-5   0.936023         0.773638  0.551540\n",
       " 0   1.000000         0.882704  0.767618\n",
       " 2   0.989477         0.921406  0.844293\n",
       " 4   0.958569         0.954161  0.909185\n",
       " 6   0.909185         0.979087  0.958569\n",
       " 8   0.844293         0.994689  0.989477\n",
       " 9   0.807175         0.998667  0.997359\n",
       " 10  0.767618         1.000000  1.000000\n",
       " 12  0.683296         0.994689  0.989477\n",
       " 14  0.595504         0.979087  0.958569\n",
       " 16  0.508127         0.954161  0.909185\n",
       " 18  0.424493         0.921406  0.844293\n",
       " 20  0.347201         0.882704  0.767618\n",
       " 23  0.246842         0.818077  0.639581"
      ]
     },
     "execution_count": 48,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "gauss_prop.dataframe"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Normal Distribution (applies the Gauss function using a computed stdDev and mean)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Over a Property"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 49,
   "metadata": {},
   "outputs": [],
   "source": [
    "normal_prop = tools.imagecollection.normalDistributionProperty(collection, 'test')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 50,
   "metadata": {},
   "outputs": [],
   "source": [
    "normal_prop_chart = ui.chart.Image.series(normal_prop, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', properties=['NORMAL_DISTRIBUTION'], label_properties=['defualt'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 51,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.jupyter.widget-view+json": {
       "model_id": "3e2a0ad2b349453aaf5cc301b6502fca",
       "version_major": 2,
       "version_minor": 0
      },
      "text/plain": [
       "HTML(value='<embed src=data:image/svg+xml;charset=utf-8;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTg…"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "normal_prop_chart.renderWidget(width=800)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 52,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>defualt</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>-32</th>\n",
       "      <td>0.001287</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-20</th>\n",
       "      <td>0.007266</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-15</th>\n",
       "      <td>0.012136</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-8</th>\n",
       "      <td>0.020259</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-5</th>\n",
       "      <td>0.023448</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.027123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>0.027780</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.027901</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>0.027479</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>0.026538</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>0.025889</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>0.025133</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>0.023339</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>0.021253</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>0.018978</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>0.016618</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>0.014269</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>0.010943</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      defualt\n",
       "-32  0.001287\n",
       "-20  0.007266\n",
       "-15  0.012136\n",
       "-8   0.020259\n",
       "-5   0.023448\n",
       " 0   0.027123\n",
       " 2   0.027780\n",
       " 4   0.027901\n",
       " 6   0.027479\n",
       " 8   0.026538\n",
       " 9   0.025889\n",
       " 10  0.025133\n",
       " 12  0.023339\n",
       " 14  0.021253\n",
       " 16  0.018978\n",
       " 18  0.016618\n",
       " 20  0.014269\n",
       " 23  0.010943"
      ]
     },
     "execution_count": 52,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "normal_prop_chart.dataframe"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Over a Band"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 53,
   "metadata": {},
   "outputs": [],
   "source": [
    "normal_band = tools.imagecollection.normalDistributionBand(collection, 'test')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 54,
   "metadata": {},
   "outputs": [],
   "source": [
    "normal_band_chart = ui.chart.Image.series(normal_band, ee.Geometry.Point([0, 0]), scale=1000, xProperty='test', bands=['normal_distribution'], label_bands=['defualt'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 55,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.jupyter.widget-view+json": {
       "model_id": "d1b596d0e3e64b4dbd0da64f7f9b800d",
       "version_major": 2,
       "version_minor": 0
      },
      "text/plain": [
       "HTML(value='<embed src=data:image/svg+xml;charset=utf-8;base64,PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0ndXRmLTg…"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "normal_band_chart.renderWidget(width=800)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 56,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>defualt</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>-32</th>\n",
       "      <td>0.001287</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-20</th>\n",
       "      <td>0.007266</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-15</th>\n",
       "      <td>0.012136</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-8</th>\n",
       "      <td>0.020259</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>-5</th>\n",
       "      <td>0.023448</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>0.027123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>0.027780</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0.027901</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>0.027479</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>0.026538</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>0.025889</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>10</th>\n",
       "      <td>0.025133</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>12</th>\n",
       "      <td>0.023339</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>14</th>\n",
       "      <td>0.021253</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>16</th>\n",
       "      <td>0.018978</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>18</th>\n",
       "      <td>0.016618</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>20</th>\n",
       "      <td>0.014269</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>23</th>\n",
       "      <td>0.010943</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      defualt\n",
       "-32  0.001287\n",
       "-20  0.007266\n",
       "-15  0.012136\n",
       "-8   0.020259\n",
       "-5   0.023448\n",
       " 0   0.027123\n",
       " 2   0.027780\n",
       " 4   0.027901\n",
       " 6   0.027479\n",
       " 8   0.026538\n",
       " 9   0.025889\n",
       " 10  0.025133\n",
       " 12  0.023339\n",
       " 14  0.021253\n",
       " 16  0.018978\n",
       " 18  0.016618\n",
       " 20  0.014269\n",
       " 23  0.010943"
      ]
     },
     "execution_count": 56,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "normal_band_chart.dataframe"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.5.2"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
